<!DOCTYPE html>
<html>

	<head>
		<meta charset="UTF-8">
		<script type="text/javascript" src="js/HomePageJs/iquery-1.12.4/jquery-1.12.4.min.js"></script>
		<script type="text/javascript" src="js/HomePageJs/layer-v3.1.1/layer/layer.js"></script>
		<link rel="stylesheet" href="js/bootstrap-3.3.7-dist/css/bootstrap.min.css" />
		<link rel="stylesheet" href="css/perinfo.css" />
		<script type="text/javascript">
			function subInfo() {
				// 错误提示信息
				var strMsg = "";
				// 用户名验证
				var username = document.getElementById("username").value;
				if(username == null || username == "") {
					// 增加提示信息
					strMsg += "请输入用户名!\n";
				}
				if(strMsg == "") {
					// 验证通过
					return true;
				} else {
					// 验证不通过
					layer.open({
						title: '提示',
						content: strMsg
					});
					return false;
				}
			}
			function doSubmit() {
				document.getElementById("infoform").submit();
			}
		</script>
	</head>

	<body>
		<form id="infoform" method="get">
			<ul>
				<li>
					<span>用户账号：</span>
				</li>
				<br />
				<li>
					<span>用户昵称：</span>
					<input type="text" id="username" name="username" value=""> 4-20个字符，可由中英文、数字、“_”、“-”组成
				</li>
				<br />
				<li>
					<span>性别：</span>
					<input type="radio" name="usersex" id="male" value="男">男
					<input type="radio" name="usersex" id="female" value="女" style="margin-left: 40px">女
				</li>
				<br />
				<li>
					<span>生日：</span>
					<select id="month">
						<option value="">请选择月份</option>
					</select>
					<select id="day">
						<option value="">请选择日期</option>
					</select>
				</li>
				<br />
				<li>
					<span>真实姓名：</span>
					<input type="text" name="realname" id="realname" value=""> 英文长度:4-20 ，中文长度:2-10
				</li>
				<br />
				<li>
					<span>身份证号：</span>
					<input type="text" name="idcard" id="idcard" value="">
				</li>
				<br />
				<li>
					<span>邮政编码：</span>
					<input type="text" name="postcode" id="postcode" value="">
				</li>
				<br />
				<li>
					<span>收货地址：</span>
					<select id="addressprovince" name="addressprovince">
						<option value="">请选择省份</option>
					</select>
					<select id="addresscity" name="addresscity">
						<option value="">请选择城市</option>
					</select>
					<select id="addressdistrict" name="addressdistrict">
						<option value="">请选择区/县</option>
					</select>
				</li>
				<br />
				<li>
					<span>详细地址：</span>
					<input type="text" id="addressdetail" name="addressdetail" style="width:300px;" maxlength="100" value="可不填">
				</li>
			</ul>
			<br />
			<button type="submit" class="btn btn-danger" id="修改" onclick="return subInfo()">修改</button>
		</form>
	</body>

</html>